{% extends "base/base.html" %}

{% block title %}
    <title>个人设置</title>
{% endblock title %}

{% block navbar %}
    <li><a href="{% url 'main' %}">首页</a></li>
    <li class="active"><a href="{% url 'set_profile' %}">设置</a></li>
{% endblock %}

{% block username %}
    <i class="glyphicon glyphicon-user"></i>
    {{ request.user }}
{% endblock %}

{% block sidebar %}

{% endblock sidebar %}

{% block content %}

    <div class="panel panel-default">
        <div class="panel-heading">
            <h4 class="panel-title"><i class="glyphicon glyphicon-header"></i> 用户设置</h4>
        </div>

        <div class="panel-body">
            <form class="form-horizontal" action="" method='post'>
                <div class="form-group">
                    <label for="username" class="col-sm-3 control-label">选择英语水平:</label>
                    <div class="col-sm-5">
                        <select class="form-control" name="level" id="level">
                            {% for level in word_level %}
                                <option value="{{ level.id }}">{{ level.level }}</option>
                            {% endfor %}
                        </select>
                    </div>
                    <label class="col-sm-2 control-label"></label>
                </div>

                <div class="form-group">
                    <label for="password" class="col-sm-3 control-label">每天单词数量:</label>
                    <div class="col-sm-5">
                        <input type="text" class="form-control" placeholder="数量" name="nums" id="nums" />

                    </div>
                    <label class="col-sm-2 control-label"></label>
                </div>

                <div class="form-group">
                    <label class="col-sm-1 control-label"></label>
                    <div class="col-sm-8">
                        {% csrf_token %}
                        <button type="submit" class="btn btn-success btn-add col-sm-offset-3">提交</button>
                    </div>
                </div>

            </form>
        </div>

    </div>

{% endblock content %}
